<!DOCTYPE html>
<html lang="zh_CN" xmlns:th="http://www.thymeleaf.org"
      xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <meta charset="utf-8">
    <title>欢迎页</title>
    <link rel="stylesheet" href="css/bootstrap.min.css">
    <link href="css/index.css" rel="stylesheet">
    <link href="css/main.css" rel="stylesheet">
</head>
<body>
<div class="container-fluid">
    <div class="row" shiro:hasPermission="sys:statis:orderStatis">
        <div class="col-md-3">
            <div class="card p-4">
                <div class="card-body d-flex justify-content-between align-items-center">
                    <div>
                        <span class="h1 d-block font-weight-normal mb-2" id="todayOrderCount">0</span>
                        <span class="h1 font-weight-light">今日订单数</span>
                    </div>

                    <div class="h1 text-muted">
                        <i class="icon icon-people"></i>
                    </div>
                </div>
            </div>
        </div>

        <div class="col-md-3">
            <div class="card p-4">
                <div class="card-body d-flex justify-content-between align-items-center">
                    <div>
                       <span class="h1 d-block font-weight-normal mb-2" id="todayOrderAmount">￥ 0</span>
                        <span class="h1 font-weight-light">今日收入</span>
                    </div>

                    <div class="h1 text-muted">
                        <i class="icon icon-wallet"></i>
                    </div>
                </div>
            </div>
        </div>

        <div class="col-md-3">
            <div class="card p-4">
                <div class="card-body d-flex justify-content-between align-items-center">
                    <div>
                        <span class="h1 d-block font-weight-normal mb-2" id="totalOrderCount">0</span>
                        <span class="h1 font-weight-light">总订单数</span>
                    </div>

                    <div class="h1 text-muted">
                        <i class="icon icon-cloud-download"></i>
                    </div>
                </div>
            </div>
        </div>

        <div class="col-md-3">
            <div class="card p-4">
                <div class="card-body d-flex justify-content-between align-items-center">
                    <div>
                        <span class="h1 d-block font-weight-normal mb-2" id="totalOrderAmount">￥ 0</span>
                        <span class="h1 font-weight-light">总收入</span>
                    </div>

                    <div class="h1 text-muted">
                        <i class="icon icon-clock"></i>
                    </div>
                </div>
            </div>
        </div>

        <div class="col-md-3">
            <div class="card p-4">
                <div class="card-body d-flex justify-content-between align-items-center">
                    <div>
                        <span class="h1 d-block font-weight-normal mb-2" id="amount">￥ 0</span>
                        <span class="h1 font-weight-light">可用余额</span>
                    </div>
                    <a shiro:hasPermission="sys:statis:shopCash" class="btn btn-primary btn-sm " href="#" mce_href="#" title="编辑"
                       onclick="shopCash()">提现
                        <i class="fa fa-edit"></i>
                    </a>
                    <div class="h1 text-muted">
                        <i class="icon icon-people"></i>
                    </div>
                </div>
            </div>
        </div>

        <div class="col-md-3">
            <div class="card p-4">
                <div class="card-body d-flex justify-content-between align-items-center">
                    <div>
                        <span class="h1 d-block font-weight-normal mb-2" id="frozen">￥ 0</span>
                        <span class="h1 font-weight-light">冻结余额</span>
                    </div>

                    <div class="h1 text-muted">
                        <i class="icon icon-people"></i>
                    </div>
                </div>
            </div>
        </div>

        <div class="col-md-3" shiro:hasPermission="sys:statis:shopCash">
            <!--商家的私钥查看-->
            <div class="card p-4">
                <div class="gg-formTitle">
                    <span class="h1 font-weight-light">我的私钥:</span>
                </div>
                <div class="gg-formDetail gg-dashed">
                    <span class="h1 d-block font-weight-normal mb-2" id="privateKey"></span>
                </div>
            </div>
        </div>
    </div>


   <form id="createOrder" shiro:hasPermission="common:dict:edit" >
       <div>
           <div class="columns pull-left col-md-2 nopadding">
               <input type="text" name="privateKey" id="shopPrivateKey" value="" placeholder="商家私钥" class="form-control"/>
           </div>
           <div class="columns pull-left col-md-2 nopadding">
               <input type="text" name="gameMoney" placeholder="订单金额" class="form-control"/>
           </div>
           <div class="columns pull-left col-md-2 nopadding">
               <select data-placeholder="支付方式" name="payWay" class="form-control chosen-select"tabindex="2" style="width: 100%">
                   <option value="1">支付宝</option>
                   <option value="2">微信</option>
                   <option value="3">QQ钱包</option>
               </select>
           </div>
       </div>
       <span class="btn btn-success" onclick="create()">下单</span>
   </form>

    <form id="getUser" shiro:hasPermission="common:dict:edit">
        <div>
            <div class="columns pull-left col-md-2 nopadding">
                <input type="text"  id="pk" placeholder="商家私钥" class="form-control"/>
                <input type="text" id="orderId" placeholder="订单号" class="form-control"/>
            </div>
            <div class="columns pull-left col-md-3 nopadding">
                <span class="btn btn-success" onclick="getUser()">获取用户收款码</span>
                <span style="width:200px;height: 200px;" id="imgSpan"></span>
            </div>
        </div>
    </form>

    <div class="wrapper wrapper-content animated fadeInRight" shiro:hasPermission="sys:statis:shopCash">
        <div class="">
            <div class="col-sm-12" style="width: 100%">
                <div class="ibox float-e-margins">
                    <div class="card-body">
                        <div class="form-check form-check-inline">
                            <div class="custom-control custom-radio">
                                <input type="radio" class="custom-control-input radioItem" id="customControlValidation2" name="type"  value="7" checked>
                                <label class="custom-control-label" for="customControlValidation2">最近7天</label>
                            </div>
                        </div>
                        <div class="form-check form-check-inline">
                            <div class="custom-control custom-radio">
                                <input type="radio" class="custom-control-input radioItem" id="customControlValidation3" name="type" value="30" >
                                <label class="custom-control-label" for="customControlValidation3">最近30天</label>
                            </div>
                        </div>
                    </div>

                    <div class="echarts" id="echarts-bar-chart" style="height: 240px"></div>
                </div>
            </div>
        </div>
    </div>
</div>
</body>
<div th:include="include::footer"></div>
<script src="/js/appjs/sys/statis/indexStatis.js"></script>
<div shiro:hasPermission="sys:statis:shopCash">
    <script src="/js/plugins/echarts/echarts-all.js"></script>
    <!-- 自定义js -->
    <script src="/js/content.js?v=1.0.0"></script>
    <!-- ECharts data -->
    <script src="/js/appjs/sys/statis/echarts-orderStatistics.js"></script>
</div>
<script src="/js/appjs/common/dict/jquery.form.js"></script>

</html>